/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package de.tordroid.model;

import java.util.ArrayList;
import java.util.List;
import org.simpleframework.xml.Attribute;
import org.simpleframework.xml.ElementList;
import org.simpleframework.xml.Root;

/**
 *
 * @author Christian Simon
 */
@Root
public class Profile {

    @Attribute
    private String titel;
    @ElementList (required = false)
    private List<Character> characters;

    public Profile() {
        this.titel = "New Profile";   
        this.characters = new ArrayList();
    }
    
    /**
     * @return the titel
     */
    public String getTitel() {
        return titel;
    }

    /**
     * @param aTitel the titel to set
     */
    public void setTitel(String aTitel) {
        titel = aTitel;
    }

    /**
     * @return the characters
     */
    public List<Character> getCharacters() {
        return characters;
    }

    /**
     * @param characters the characters to set
     */
    public void setCharacters(List<Character> characters) {
        this.characters = characters;
    }
    
    public void addCharacter(Character character)
    {
        this.characters.add(character);
    }

    public void removeCharacter(Character character) {
        this.characters.remove(character);
    }
}
